package com.aspire.aimini.model.query;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 用户查询对象
 *
 * @author wangguiyou
 * @date 2024-12-19
 * @description 用户查询条件对象，用于分页查询
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Schema(description = "用户查询对象")
public class UserQuery extends BaseQuery implements Serializable {

    private static final long serialVersionUID = 1L;

    @Schema(description = "用户名（模糊查询）")
    private String username;

    @Schema(description = "昵称（模糊查询）")
    private String nickname;

    @Schema(description = "邮箱（模糊查询）")
    private String email;

    @Schema(description = "手机号（模糊查询）")
    private String phone;

    @Schema(description = "性别：0-未知，1-男，2-女")
    private Integer gender;

    @Schema(description = "角色：admin-管理员，user-普通用户")
    private String role;

    @Schema(description = "状态：0-禁用，1-启用")
    private Integer status;

    @Schema(description = "创建时间开始")
    private LocalDateTime createTimeStart;

    @Schema(description = "创建时间结束")
    private LocalDateTime createTimeEnd;

    @Schema(description = "最后登录时间开始")
    private LocalDateTime lastLoginTimeStart;

    @Schema(description = "最后登录时间结束")
    private LocalDateTime lastLoginTimeEnd;
}